<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>				
	</head>
	<body>
        <h3>工作经历</h3>
        
        <div id="div1">
            
        </div>
        
        <a href="#" onclick="add()">添加工作经历</a>
	</body>
    <script type="text/javascript">
        var div1Obj = document.getElementById('div1');
        function add(){
            div1Obj.innerHTML +='<div id="div2"><hr>公司名称：<input type="text">职位：<input type="text"><a href="#" onclick="delSon()">删除工作经历</a><br><br>工作职责及工作内容描述:<textarea name="" id="" cols="50" rows="5"></textarea><hr></div>';
        }

        function delSon(){
            var id3AllP = document.getElementById('div2') ;
                div1Obj.removeChild(id3AllP);
		}
        // var id3AllP = div1Obj.getElementsByTagName('div')
        // for (int; i =0;i <  id3AllP.length; i++) {
        //     const element = arint[i]; 
            
        // }
          
    </script>
</html>

